// CQSize.h: interface for the CQSize class.
//
//////////////////////////////////////////////////////////////////////

//////////////////////////////////////////////////////////////////////
//Copyright (c) 2007 Tencent
//Author : springsu
//Date : 2007-3-21 11:20:18
//Version : 
//Description : 
////////////////////////////////////////////////////////////////////////
#if !defined(AFX_QSIZE_H__89CB667F_6903_4D07_9476_88C5D614F019__INCLUDED_)
#define AFX_QSIZE_H__89CB667F_6903_4D07_9476_88C5D614F019__INCLUDED_
//////////////////////////////////////////////////////////////////////////
#include "cx_typedef.h"
#include "QPoint.h"
//////////////////////////////////////////////////////////////////////////

class CQSize  : public tagQSIZE
{
public:
	IMPORT_C CQSize();
    IMPORT_C CQSize(QINT width, QINT height);
	IMPORT_C CQSize(QSIZE initSize);
	IMPORT_C CQSize(QPOINT initPt);
	
    QINT  Width() const { return cx; }
    QINT  Height() const { return cy; }
    QVOID SetWidth(QINT width) { cx = width; }
    QVOID SetHeight(QINT height) { cy = height; }
	QVOID SetSize(int CX, int CY) { cx = CX; cy = CY;}	

	IMPORT_C QBOOL operator==(QSIZE b) const;
	IMPORT_C QBOOL operator!=(QSIZE b) const;
	IMPORT_C QVOID operator+=(QSIZE b);
	IMPORT_C QVOID operator-=(QSIZE b);

	// Operators returning CQSize values
	IMPORT_C CQSize operator+(QSIZE b) const;
	IMPORT_C CQSize operator-(QSIZE b) const;
	IMPORT_C CQSize operator-() const;
	
	// Operators returning CPoint values
	IMPORT_C CQPoint operator+(QPOINT b) const;
	IMPORT_C CQPoint operator-(QPOINT b) const;

};

#endif // !defined(AFX_QSIZE_H__89CB667F_6903_4D07_9476_88C5D614F019__INCLUDED_)
